package com.ctrip.study.refactor.simple;

import static org.junit.Assert.*;
import junit.framework.TestCase;

import org.junit.Test;

public class CustomerTest extends TestCase{

	@Test
	public void testStatement() {
		Movie movie1 = new Movie("aa", Movie.CHILDRENS);
		Movie movie2 = new Movie("bb", Movie.NEW_RELEASE);
		Movie movie3 = new Movie("cc", Movie.REGULAR);
		
		
		Rental r1 = new Rental(movie1, 7);
		Rental r2 = new Rental(movie2, 5);
		Rental r3 = new Rental(movie3, 3);
		
		Customer c1 = new Customer("wangao");
		c1.addRental(r1);
		c1.addRental(r2);
		System.out.println(c1.statement());
	}

}
